<?php

defined('SYSPATH') or die('No direct script access.');

class Viewer
{

    public static function display($v,$content_data = array()) {
        
        $content = View::factory($v);
        if(is_array($content_data) && !empty ($content_data)){
            foreach($content_data as $key=>$value) {
                $content->set($key, $value);
            }
        }
        $view = View::factory('admin/template')->set('content', $content);
        return $view;
    }

}

